<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="js/vue.js"></script>
</head>
<body>
    <div id="app">
        <p>{{ msg }}</p>

        <button @click="msg='欢迎'">修改</button>
    </div>

    <script>
        new Vue({
            el: '#app',
            data: {
                msg: 'welcome to vue'
            },
            created(){
                console.log('Vue实例创建完毕......')
            },
            mounted(){
                console.log('已挂载......')
            },
            updated(){
                console.log('页面已更新......')
            }
        })
    </script>
</body>
</html>